package com.nbc.car.biz.entity;

import java.util.Date;
import java.util.List;

/**
 * Created by yp-bp-m-7046 on 16/7/19.
 */
public class CUser {
    /**
    c端用户id,主键
     */
    private long cUserId;
    /**
    电话 用于用户登陆
     */
    private String phone;
    /**
    登陆密码
     */
    private String password;
    /**
    用户名,用于在页面显示
     */
    private String name;
    /**
    性别 非必填
     */
    private short gender;
    /**
    生日
     */
    private Date birthday;
    /**
    创建时间-注册时间 系统默认
     */
    private Date createTime;
    /**
    用户长传头像等照片
     */
    private List<Photo> photos;
    /**
    用户令牌 用于模拟sessionId
     */
    private Token token;

    /**
    用户所有车辆集合
     */
    private List<Car> cars;

    public CUser(){}

    public CUser(String phone, String password) {
        this.phone = phone;
        this.password = password;
    }

    public long getcUserId() {
        return cUserId;
    }

    public void setcUserId(long cUserId) {
        this.cUserId = cUserId;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public short getGender() {
        return gender;
    }

    public void setGender(short gender) {
        this.gender = gender;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public List<Photo> getPhotos() {
        return photos;
    }

    public void setPhotos(List<Photo> photos) {
        this.photos = photos;
    }

    public Token getToken() {
        return token;
    }

    public void setToken(Token token) {
        this.token = token;
    }

    public List<Car> getCars() {
        return cars;
    }

    public void setCars(List<Car> cars) {
        this.cars = cars;
    }

    @Override
    public String toString() {
        return "CUser{" +
                "cUserId=" + cUserId +
                ", phone='" + phone + '\'' +
                ", password='" + password + '\'' +
                ", name='" + name + '\'' +
                ", gender=" + gender +
                ", birthday=" + birthday +
                ", createTime=" + createTime +
                ", photos=" + photos +
                ", token=" + token +
                ", cars=" + cars +
                '}';
    }
}